from core.basic.skill import 技能
from core.basic.character import Character
from core.basic.skill import 主动技能, 被动技能


class 主动技能(主动技能):
    风雷啸 = 1.0

    def 等效百分比(self, **argv):
        return super().等效百分比(**argv)*self.风雷啸


class 技能0(被动技能):  # 基础精通
    名称 = '基础精通'
    倍率 = 1.0

    所在等级 = 1
    等级上限 = 200
    学习间隔 = 1
    等级精通 = 110

    关联技能 = ['念兽：龙虎啸']

    def 加成倍率(self, 武器类型):
        if self.等级 == 0:
            return 1.0
        else:
            return round(self.倍率 * (0.463 + 0.089 * self.等级), 5)


class 技能1(主动技能):  # 分身
    名称 = '分身'
    所在等级 = 5
    等级上限 = 20
    学习间隔 = 2
    等级精通 = 10
    MP = [6, 84]
    基础个数 = 0
    是否有伤害 = 0
    TP上限 = 0
    关联技能 = ['幻影爆碎']

    def 加成倍率(self, 武器类型):
        if self.等级 == 0:
            return 0
        else:
            return self.基础个数 + self.等级


class 技能2(主动技能):  # 雷霆踏
    名称 = '雷霆踏'
    所在等级 = 15
    等级上限 = 70
    学习间隔 = 2
    等级精通 = 60
    MP = [20, 146]
    data0 = [int(i*1.05*1.05) for i in [0, 4444, 4893, 5345, 5796, 6247, 6697, 7148, 7599, 8050, 8501, 8951, 9402, 9853, 10304, 10754, 11205, 11656, 12108, 12558, 13009, 13460, 13911, 14361, 14812, 15263, 15714, 16164, 16615, 17066, 17517, 17967, 18418, 18869, 19321,
                                   19770, 20222, 20673, 21124, 21574, 22025, 22476, 22927, 23378, 23828, 24279, 24730, 25181, 25631, 26082, 26533, 26985, 27434, 27886, 28337, 28788, 29238, 29689, 30140, 30591, 31041, 31492, 31943, 32394, 32844, 33295, 33746, 34197, 34647, 35098, 35550]]
    hit0 = 1
    感电data0 = [int(i*1.05*1.05) for i in [0, 548, 604, 659, 716, 772, 828, 883, 939, 995, 1050, 1106, 1162, 1217, 1273, 1328, 1384, 1440, 1495, 1551, 1608, 1664, 1719, 1775, 1830, 1886, 1942, 1997, 2053, 2109, 2164, 2220, 2276, 2331,
                                     2387, 2443, 2498, 2555, 2611, 2666, 2722, 2778, 2833, 2889, 2945, 3000, 3056, 3112, 3167, 3223, 3278, 3334, 3390, 3445, 3502, 3558, 3614, 3669, 3725, 3781, 3836, 3892, 3947, 4003, 4059, 4114, 4170, 4226, 4281, 4337, 4394]]
    感电hit0 = 1
    CD = 7.0
    TP成长 = 0.10
    TP上限 = 7


class 技能3(主动技能):  # 念气波
    名称 = '念气波'
    所在等级 = 15
    等级上限 = 70
    学习间隔 = 2
    等级精通 = 60
    MP = [15, 154]
    data0 = [int(i*1.053*1.059) for i in [0, 1693, 1864, 2037, 2208, 2379, 2552, 2723, 2895, 3067, 3239, 3410, 3581, 3754, 3925, 4097, 4269, 4441, 4612, 4785, 4956, 5128, 5300, 5471, 5643, 5815, 5987, 6158, 6331, 6502, 6674, 6846, 7018, 7189, 7361,
                                    7533, 7704, 7877, 8048, 8220, 8392, 8564, 8735, 8906, 9079, 9250, 9422, 9594, 9766, 9937, 10110, 10281, 10452, 10625, 10796, 10968, 11140, 11312, 11483, 11656, 11827, 11998, 12171, 12342, 12514, 12686, 12858, 13029, 13202, 13373, 13545]]
    hit0 = 1
    感电data0 = [int(i*1.053*1.059) for i in [0, 188, 207, 226, 245, 264, 282, 303, 322, 340, 359, 378, 397, 416, 436, 455, 474, 493, 512, 531, 550, 570, 589, 608, 626, 645, 664, 683, 703, 722, 741, 760, 779, 798, 818,
                                      837, 856, 875, 894, 913, 931, 952, 970, 989, 1008, 1027, 1046, 1065, 1085, 1104, 1123, 1142, 1161, 1180, 1199, 1219, 1238, 1256, 1275, 1294, 1313, 1332, 1352, 1371, 1390, 1409, 1428, 1447, 1467, 1486, 1505]]
    感电hit0 = 1
    CD = 2.5
    TP成长 = 0.10
    TP上限 = 7


class 技能4(主动技能):  # 蓄念炮 是被动不能受1-35主动技能+xx的加成
    名称 = '蓄念炮'

    所在等级 = 20
    等级上限 = 11
    学习间隔 = 2
    等级精通 = 1

    MP = [40, 56]
    CD = 8.0

    是否主动 = 0

    TP上限 = 1

    # 这里需要加一个蓄念炮的tp
    # 蓄念炮TP的加成倍率和蓄念炮本身等级有关，从1到11级各不相同
    # 蓄念炮TP下的蓄念炮倍率为(0.18+蓄念炮等级*0.01)*14;无tp下蓄念炮倍率为(2.59+蓄念炮等级*0.06)
    # 两者相除即是蓄念炮TP所带来的额外倍率
    # 上述描述是针对念气波直伤部分的，关于蓄念炮TP感电部分的额外倍率为(1/(2.59+蓄念炮等级*0.06))；

    def 等效百分比(self, **argv):
        # 武器类型 额外等级 额外倍率 伤害类型 形态
        武器类型 = argv.get('武器类型', '')
        额外等级 = argv.get('额外等级', 0)
        额外倍率 = argv.get('额外倍率', 1.0)
        伤害类型 = argv.get('伤害类型', '直伤')
        形态 = argv.get('形态', '')
        char = argv.get('char', {})

        百分比 = char.get_skill_by_name("念气波").等效百分比(伤害类型=伤害类型)

        if self.等级 == 0:
            倍率 = 1.0
        else:
            倍率 = round(2.59 + 0.06 * self.等级, 5)
        if self.TP等级 > 0:
            倍率 = (0.18+self.等级*0.01)*14

        return 百分比 * 倍率 * self.倍率 * 额外倍率


# 幻爆的伤害实质属于被动技能，不能受1-35主动技能+xx的加成
# MP消耗也是按分身的等级来
class 技能5(主动技能):  # 幻影爆碎 TP加分身个数
    名称 = '幻影爆碎'
    是否主动 = 0
    所在等级 = 20
    等级上限 = 70
    学习间隔 = 2
    等级精通 = 60
    是否主动 = 0
    data0 = [int(i*1.051*1.051) for i in [0, 873, 962, 1050, 1139, 1228, 1317, 1405, 1494, 1583, 1671, 1760, 1849, 1938, 2026, 2115, 2204, 2292, 2381, 2469, 2557, 2646, 2735, 2824, 2912, 3001, 3090, 3179, 3267, 3356, 3445, 3533, 3622, 3711,
                                    3800, 3888, 3977, 4066, 4153, 4242, 4331, 4420, 4508, 4597, 4686, 4774, 4863, 4952, 5041, 5129, 5218, 5307, 5396, 5484, 5573, 5662, 5750, 5838, 5927, 6015, 6104, 6193, 6282, 6370, 6459, 6548, 6636, 6725, 6814, 6903, 6991]]
    CD = 12
    TP上限 = 7

    def TP加成(self):
        return 1.0


class 技能6(主动技能):  # 念雷轰  #data部分需后续核对
    名称 = '念雷轰'
    所在等级 = 25
    等级上限 = 70
    学习间隔 = 2
    等级精通 = 60
    MP = [20, 167]  # 计算可得
    data0 = [int(i*1.581) for i in [0, 818, 901, 984, 1067, 1150, 1233, 1316, 1399, 1482, 1565,
                              1649, 1732, 1815, 1898, 1981, 2064, 2147, 2230, 2313, 2396,
                              2479, 2562, 2645, 2728, 2811, 2894, 2977, 3060, 3143, 3309,
                              3392, 3476, 3559, 3642, 3725, 3808, 3891, 3974, 4057, 4140,
                              4223, 4306, 4389, 4472, 4555, 4638, 4721, 4804, 4887, 4970,
                              5053, 5136, 5219, 5302, 5385, 5468, 5551, 5634, 5717, 5800,
                              5883, 5966, 6049, 6132, 6215, 6298, 6381, 6464, 6547, 6630]]
    hit0 = 4
    感电data0 = [int(i*1.581) for i in [0, 90, 100, 109, 118, 127, 137, 146, 155, 164, 173,
                                183, 192, 201, 210, 220, 229, 238, 247, 257, 266,
                                275, 284, 293, 303, 312, 321, 330, 340, 358, 367,
                                376, 386, 395, 404, 413, 423, 432, 441, 450, 460,
                                469, 478, 487, 496, 506, 515, 524, 533, 542, 552,
                                561, 570, 579, 588, 598, 607, 616, 625, 634, 644,
                                653, 662, 671, 680, 690, 699, 708, 717, 726, 736]]
    感电hit0 = 4
    CD = 7
    TP成长 = 0.10
    TP上限 = 7


class 技能7(主动技能):
    名称 = '念气环绕'
    所在等级 = 20
    等级上限 = 35
    学习间隔 = 3
    等级精通 = 25
    MP = [5, 210]
    关联技能 = ['所有']
    data0 = [int(i*1.052*1.051) for i in [0, 60, 70, 79, 90, 99, 109, 118, 128, 139, 148, 157, 167, 176, 187, 197,
                                    206, 215, 225, 236, 245, 255, 264, 274, 284, 294, 303, 313, 322, 333, 342, 352, 361, 371, 381, 391]]
    # 念气环绕 开御（全程）一秒10次
    hit0 = 1
    CD = 4
    关联技能 = ['念气环绕：御']
    关联技能2 = ['所有']

    def 加成倍率(self, 武器类型):
        return self.data0[self.等级] * self.攻击次数 * self.倍率/100

    def 加成倍率2(self, 武器类型):
        if (self.等级 <= 25):
            return round(1.00 + 0.01 * self.等级, 5)
        else:
            return round(1.25 + 0.02 * (self.等级 - 25), 5)


class 技能8(主动技能):  # 念气环绕：袭
    名称 = '念气环绕：袭'
    所在等级 = 25
    等级上限 = 11
    学习间隔 = 2
    等级精通 = 1
    MP = [75, 630]
    data0 = [int(i*1.05*1.082) for i in [0, 18993, 19397, 19803, 20208,
                                   20613, 21019, 21424, 21829, 22234, 22640, 23045]]
    hit0 = 1
    CD = 4.5


class 技能9(主动技能):
    名称 = '念气环绕：御'
    所在等级 = 30
    等级上限 = 11
    学习间隔 = 2
    等级精通 = 1
    MP = [200, 980]
    # 这里的data0实质上是倍率；念气环绕里有个对念气环绕：御额外加成倍率，那个是技能百分比
    data0 = [int(i) for i in [0, 151, 154, 157, 160,
                              163, 166, 169, 172, 175, 178, 181]]
    # 念气环绕：御  一秒10次
    hit0 = 10
    CD = 1


# 其风雷啸部分需要后续确认
class 技能10(主动技能):  # 天雷虎踢 1层感电 data部分需后续核对
    名称 = "天雷虎踢"
    所在等级 = 35
    学习间隔 = 2
    等级上限 = 70
    等级精通 = 60

    data0 = [int(i*1.081) for i in [0, 5528, 6089, 6649, 7210, 7771, 8332, 8893, 9454, 10015, 10575,
                              11136, 11697, 12258, 12819, 13380, 13940, 14501, 15062, 15623, 16184,
                              16745, 17305, 17866, 18427, 18988, 19579, 20110, 20670, 21231, 21792,
                              22353, 22914, 23475, 24036, 24596, 25157, 25718, 26279, 26840, 27401,
                              27961, 28522, 29083, 29644, 30205, 30766, 31327, 31888, 32449, 33010,
                              33571, 34132, 34693, 35254, 35815, 36376, 36937, 37498, 38059, 38620,
                              39181, 39742, 40303, 40864, 41425, 41986, 42547, 43108, 43669, 44230]]
    hit0 = 1
    data1 = [int(i*1.351) for i in [0, 157, 173, 189, 206, 222, 238, 254, 270, 286, 302,
                              318, 334, 350, 366, 382, 398, 414, 430, 446, 462,
                              478, 494, 510, 526, 542, 558, 574, 590, 606, 622,
                              638, 654, 670, 686, 702, 718, 734, 750, 766, 782,
                              798, 814, 830, 846, 862, 878, 894, 910, 926, 942,
                              958, 974, 990, 1006, 1022, 1038, 1054, 1070, 1086, 1102,
                              1118, 1134, 1150, 1166, 1182, 1198, 1214, 1230, 1246, 1262]]
    hit1 = 8
    感电data0 = [int(i*1.351) for i in [0, 78, 86, 94, 103, 111, 119, 127, 135, 143, 151,
                                159, 167, 175, 183, 191, 199, 207, 215, 223, 231,
                                239, 247, 255, 263, 271, 279, 287, 295, 303, 311,
                                319, 327, 335, 343, 351, 359, 367, 375, 383, 391,
                                399, 407, 415, 423, 431, 439, 447, 455, 463, 471,
                                479, 487, 495, 503, 511, 519, 527, 535, 543, 551,
                                559, 567, 575, 583, 591, 599, 607, 615, 623, 631]]
    感电hit0 = 8
    风雷啸 = 1.70  # 风雷啸
    CD = 17.0
    TP成长 = 0.10
    TP上限 = 5

    MP = [120, 1008]
    无色消耗 = 1

    形态 = ['风雷啸', '普通']

    def 形态变更(self, 形态, char):
        if 形态 == '' and len(self.形态) > 0:
            形态 = self.形态[0]
        if 形态 == "风雷啸":
            self.风雷啸 = 1.70
        if 形态 == "普通":
            self.风雷啸 = 1.00


class 技能11(主动技能):  # 狮子吼
    名称 = '狮子吼'
    所在等级 = 35
    等级上限 = 70
    学习间隔 = 2
    等级精通 = 60

    data0 = [int(i*1.05*1.05) for i in [0, 6693, 7372, 8051, 8730, 9409, 10088, 10767, 11446, 12125, 12804, 13483, 14162, 14841, 15520, 16199, 16878, 17558, 18236, 18916, 19594, 20274, 20952, 21632, 22310, 22990, 23668, 24348, 25027, 25706, 26385, 27064, 27743, 28422,
                                   29102, 29780, 30460, 31138, 31818, 32496, 33176, 33854, 34534, 35212, 35892, 36570, 37250, 37928, 38608, 39286, 39966, 40644, 41324, 42002, 42682, 43360, 44040, 44718, 45398, 46077, 46756, 47435, 48114, 48793, 49472, 50151, 50830, 51510, 52188, 52868, 53546]]
    hit0 = 1
    风雷啸 = 1.70  # 风雷啸
    CD = 17
    TP成长 = 0.10
    TP上限 = 5
    是否有护石 = 1

    MP = [120, 1008]
    无色消耗 = 1

    形态 = ['风雷啸', '普通']

    def 形态变更(self, 形态, char):
        if 形态 == '' and len(self.形态) > 0:
            形态 = self.形态[0]
        if 形态 == "风雷啸":
            self.风雷啸 = 1.70
        if 形态 == "普通":
            self.风雷啸 = 1.00

    def 装备护石(self):
        self.倍率 *= 1.37


class 技能12(主动技能):  # 螺旋念气场
    名称 = '螺旋念气场'
    所在等级 = 40
    等级上限 = 70
    学习间隔 = 2
    等级精通 = 60

    data0 = [int(i*1.05*1.058) for i in [0, 606, 668, 729, 791, 852, 914, 976, 1037, 1099, 1160, 1222, 1283, 1345, 1407, 1468, 1531, 1592, 1654, 1716, 1777, 1839, 1900, 1962, 2023, 2085, 2147, 2208, 2270, 2331, 2393, 2454, 2516, 2578,
                                   2639, 2701, 2762, 2824, 2885, 2947, 3009, 3070, 3132, 3193, 3255, 3316, 3378, 3440, 3501, 3563, 3624, 3686, 3747, 3809, 3870, 3932, 3994, 4055, 4117, 4178, 4240, 4301, 4363, 4425, 4486, 4548, 4609, 4671, 4732, 4794, 4856]]
    hit0 = 17
    风雷啸 = 1.70  # 风雷啸
    感电data0 = [int(i*1.05*1.058) for i in [0, 271, 298, 326, 354, 381, 408, 437, 464, 491, 519, 547, 574, 601, 629, 657, 684, 712, 739, 767, 794, 822, 850, 877, 905, 932, 960, 987, 1015, 1042, 1070, 1098, 1125, 1153, 1180, 1208,
                                     1235, 1263, 1291, 1318, 1345, 1373, 1401, 1428, 1456, 1484, 1511, 1538, 1566, 1594, 1621, 1648, 1677, 1704, 1731, 1759, 1787, 1814, 1841, 1870, 1897, 1924, 1951, 1980, 2007, 2034, 2063, 2090, 2117, 2144, 2173]]
    感电hit0 = 1
    CD = 20.0
    TP成长 = 0.10
    TP上限 = 5
    是否有护石 = 1

    MP = [170, 1428]
    无色消耗 = 1

    形态 = ['风雷啸', '普通']

    def 形态变更(self, 形态, char):
        if 形态 == '' and len(self.形态) > 0:
            形态 = self.形态[0]
        if 形态 == "风雷啸":
            self.风雷啸 = 1.70
        if 形态 == "普通":
            self.风雷啸 = 1.00

    def 装备护石(self):  # 1.09 0.83
        self.倍率 *= 1.18
        self.CD *= 0.83


class 技能13(主动技能):  # 念兽：龙虎啸
    名称 = '念兽：龙虎啸'
    所在等级 = 30
    等级上限 = 20
    学习间隔 = 3
    等级精通 = 10
    MP = [357, 2911]
    # 第1击魔法武器攻击力：<int>%
    data0 = [int(i) for i in [0, 160, 160, 160, 160, 160, 160, 160,
                              160, 160, 160, 160, 160, 160, 160, 160, 160, 160, 160, 160, 160]]
    hit0 = 1
    # 第2击魔法武器攻击力：<int>%
    data1 = [int(i) for i in [0, 180, 180, 180, 180, 180, 180, 180,
                              180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180, 180]]
    hit1 = 1
    # 第3击魔法武器攻击力：<int>%
    data2 = [int(i) for i in [0, 200, 200, 200, 200, 200, 200, 200,
                              200, 200, 200, 200, 200, 200, 200, 200, 200, 200, 200, 200, 200]]
    hit2 = 1
    # 第4击魔法武器攻击力：<int>%
    data3 = [int(i) for i in [0, 220, 220, 220, 220, 220, 220, 220,
                              220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220]]
    hit3 = 1
    # 第5击魔法武器攻击力：<int>%
    data4 = [int(i) for i in [0, 240, 240, 240, 240, 240, 240, 240,
                              240, 240, 240, 240, 240, 240, 240, 240, 240, 240, 240, 240, 240]]
    hit4 = 1
    # 感电只有最后一击才会赋予
    感电data0 = [int(i) for i in [0, 14, 14, 14, 14, 14, 14, 14,
                                14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14]]
    感电hit0 = 1
    CD = 1.0

    关联技能 = ['所有']

    def 加成倍率(self, 武器类型):
        if self.等级 == 0:
            return 1.0
        elif self.等级 < 7:
            return round(1.17 + 0.01 * self.等级, 5)
        else:
            return round(1.3 + 0.02 * (self.等级-10), 5)


class 技能14(主动技能):  # 念兽：猛虎震地  CP武器 爆炸=多段（多段*2）
    名称 = '念兽：猛虎震地'
    所在等级 = 45
    等级上限 = 70
    学习间隔 = 2
    等级精通 = 60

    data0 = [int(i*1.053) for i in [0, 2245, 2473, 2701, 2929, 3157, 3385, 3612, 3840, 4068, 4296, 4524, 4751, 4980, 5207, 5436, 5663, 5890, 6119, 6346, 6575, 6802, 7031, 7258, 7485, 7714, 7941, 8170, 8397, 8625, 8853, 9081, 9309, 9536, 9764, 9992, 10220,
                              10448, 10676, 10903, 11131, 11359, 11587, 11815, 12042, 12271, 12498, 12727, 12954, 13181, 13410, 13637, 13866, 14093, 14322, 14549, 14776, 15005, 15232, 15461, 15688, 15917, 16144, 16372, 16600, 16827, 17056, 17283, 17511, 17739, 17967]]
    hit0 = 4
    data1 = [int(i*1.053) for i in [0, 8983, 9895, 10806, 11717, 12629, 13540, 14452, 15362, 16274, 17186, 18097, 19008, 19920, 20831, 21743, 22653, 23565, 24477, 25389, 26299, 27211, 28122, 29034, 29945, 30856, 31768, 32680, 33590, 34502, 35413, 36325, 37236, 38147,
                              39059, 39971, 40881, 41793, 42705, 43616, 44527, 45438, 46350, 47262, 48172, 49084, 49996, 50907, 51818, 52729, 53641, 54553, 55463, 56375, 57287, 58198, 59109, 60021, 60932, 61844, 62754, 63666, 64578, 65489, 66400, 67312, 68223, 69135, 70045, 70957, 71869]]
    hit1 = 1
    风雷啸 = 1.7  # 风雷啸，分成4段
    CD = 45
    TP成长 = 0.10
    TP上限 = 5
    是否有护石 = 1

    MP = [450, 3780]
    无色消耗 = 2

    形态 = ['风雷啸', '普通']

    def 形态变更(self, 形态, char: Character):
        if 形态 == '' and len(self.形态) > 0:
            形态 = self.形态[0]
        if 形态 == "风雷啸":
            self.风雷啸 = 1.70
            if '念兽：猛虎震地' in char.护石栏:
                self.风雷啸 = 1.49+0.7
        if 形态 == "普通":
            self.风雷啸 = 1.00
            if '念兽：猛虎震地' in char.护石栏:
                self.风雷啸 = 1.49

    def 装备护石(self):  # 风雷啸部分不受护石的加成
        pass


class 技能15(被动技能):  # 念之奥义 一觉被动
    名称 = '念之奥义'
    所在等级 = 48
    等级上限 = 50
    学习间隔 = 3
    等级精通 = 40

    关联技能 = ['所有']

    # 增伤倍率 *= 1 + self.暴击伤害
    def 加成倍率(self, 武器类型):
        if self.等级 == 0:
            return 1.0
        else:
            return round(1.055 + 0.015 * self.等级, 5)


class 技能16(主动技能):  # 念兽：审判之金雷虎 一觉
    名称 = '念兽：审判之金雷虎'
    所在等级 = 50
    等级上限 = 50
    学习间隔 = 5
    等级精通 = 40

    # 金雷虎身体攻击力：<data0>%
    data0 = [int(i*1.053*1.054) for i in [0, 2315, 2852, 3389, 3926, 4463, 5000, 5537, 6074, 6611, 7148, 7685, 8222, 8759, 9296, 9833, 10370, 10907, 11444, 11981,
                                    12518, 13055, 13592, 14129, 14666, 15203, 15740, 16277, 16814, 17351, 17888, 18425, 18962, 19499, 20036, 20574, 21111, 21648, 22185, 22722, 23259]]
    hit0 = 6
    # 金雷虎落地时的冲击波攻击力：<data1>%
    data1 = [int(i*1.053*1.054) for i in [0, 6286, 7742, 9200, 10658, 12115, 13573, 15031, 16488, 17946, 19404, 20861, 22319, 23775, 25233, 26691, 28148, 29606, 31064,
                                    32522, 33979, 35437, 36895, 38352, 39810, 41266, 42724, 44182, 45639, 47097, 48555, 50012, 51470, 52928, 54385, 55843, 57300, 58757, 60215, 61673, 63130]]
    hit1 = 3
    # 金雷虎爆炸攻击力：<data2>%
    data2 = [int(i*1.053*1.054) for i in [0, 16872, 20784, 24696, 28609, 32522, 36434, 40347, 44259, 57806, 62499, 67196, 71891, 76584, 81281, 85976, 90669, 95364, 100060, 104754,
                                    109449, 114145, 118839, 123534, 128228, 132924, 137619, 142313, 147009, 151704, 156398, 161093, 165789, 170483, 175178, 179874, 184568, 189263, 193958, 198653, 203348]]
    hit2 = 1
    CD = 145

    MP = [900, 7560]
    无色消耗 = 5


class 技能17(主动技能):  # 念之战矛
    名称 = '念之战矛'
    所在等级 = 60
    等级上限 = 50
    学习间隔 = 2
    等级精通 = 40

    data0 = [int(i*1.05*1.059) for i in [3417, 3763, 4110, 4456, 4803, 5150, 5496, 5843, 6189, 6536, 6883, 7229, 7576, 7923, 8269, 8616, 8962, 9309, 9656, 10002, 10350, 10697, 11043, 11390,
                                   11737, 12083, 12430, 12776, 13123, 13470, 13816, 14163, 14509, 14856, 15203, 15549, 15896, 16243, 16589, 16936, 17282, 17629, 17976, 18322, 18669, 19016, 19362, 19709, 20055, 20402]]
    hit0 = 1
    data1 = [int(i*1.05*1.059) for i in [13667, 15054, 16440, 17828, 19214, 20601, 21987, 23374, 24760, 26147, 27533, 28920, 30307, 31694, 33080, 34467, 35853, 37240, 38626, 40013, 41400, 42787, 44173,
                                   45560, 46946, 48333, 49719, 51106, 52492, 53880, 55266, 56653, 58039, 59426, 60812, 62199, 63585, 64972, 66359, 67746, 69132, 70519, 71905, 73292, 74678, 76065, 77452, 78839, 80225, 81612]]
    hit1 = 1
    感电data0 = [int(i*1.05*1.059) for i in [12, 13, 14, 15, 17, 18, 19, 20, 21, 22, 24, 25, 26, 27, 28, 30, 31, 32, 33, 34, 35,
                                     37, 38, 39, 40, 41, 43, 44, 45, 46, 47, 49, 50, 51, 52, 53, 54, 56, 57, 58, 59, 60, 62, 63, 64, 65, 66, 67, 69, 70]]
    感电hit0 = 1
    风雷啸 = 1.7  # 风雷啸
    CD = 30
    TP成长 = 0.10
    TP上限 = 5
    是否有护石 = 1

    MP = [450, 1260]
    无色消耗 = 1

    形态 = ['风雷啸', '普通']

    def 形态变更(self, 形态, char: Character):
        if 形态 == '' and len(self.形态) > 0:
            形态 = self.形态[0]
        if 形态 == "风雷啸":
            self.风雷啸 = 1.70
            if '念之战矛' in char.护石栏:
                # 护石会删除掉本体的伤害，但不会删除风雷啸的部分
                # 但同样，护石也只会加成本体的伤害，不会加成风雷啸的伤害
                self.power1 = (1.99+0.7)/1.7
        if 形态 == "普通":
            self.风雷啸 = 1.00
            if '念之战矛' in char.护石栏:
                self.power1 = 1.99

    def 装备护石(self):
        self.hit0 = 0
        self.hit1 = 1
        self.感电hit0 = 0
        pass


class 技能18(主动技能):  # 冲云念气场
    名称 = '冲云念气场'
    所在等级 = 70
    等级上限 = 50
    学习间隔 = 2
    等级精通 = 40

    data0 = [int(i*1.052*1.056) for i in [0, 3966, 4369, 4770, 5173, 5575, 5978, 6380, 6783, 7185, 7587, 7989, 8392, 8794, 9197, 9599, 10001, 10403, 10806, 11209, 11611, 12014, 12416, 12818, 13220,
                                    13623, 14025, 14428, 14830, 15232, 15634, 16037, 16439, 16842, 17244, 17647, 18048, 18451, 18854, 19256, 19659, 20061, 20463, 20865, 21268, 21670, 22073, 22475, 22878, 23279, 23682]]
    hit0 = 6
    感电data0 = [int(i*1.052*1.056) for i in [0, 490, 540, 590, 638, 688, 738, 788, 837, 887, 937, 987, 1036, 1086, 1136, 1186, 1235, 1285, 1335, 1385, 1434, 1484, 1534, 1584, 1633,
                                1683, 1733, 1783, 1833, 1882, 1932, 1982, 2032, 2081, 2131, 2181, 2231, 2280, 2330, 2380, 2430, 2478, 2528, 2579, 2629, 2677, 2727, 2777, 2827, 2876, 2926]]
    感电hit0 = 6
    风雷啸 = 1.7  # 风雷啸
    CD = 50
    TP成长 = 0.10
    TP上限 = 5
    是否有护石 = 1

    MP = [800, 1680]
    无色消耗 = 2

    形态 = ['风雷啸', '普通']

    def 形态变更(self, 形态, char: Character):
        if 形态 == '' and len(self.形态) > 0:
            形态 = self.形态[0]
        if 形态 == "风雷啸":
            self.风雷啸 = 1.70
            if '冲云念气场' in char.护石栏:
                # 护石会直接取代原本风雷啸的加成
                self.风雷啸 = 2.3
        if 形态 == "普通":
            self.风雷啸 = 1.00

    def 装备护石(self):
        pass


class 技能19(主动技能):  # 奔雷螺旋击
    名称 = '奔雷螺旋击'
    所在等级 = 75
    等级上限 = 50
    学习间隔 = 2
    等级精通 = 40

    data0 = [int(i*1.054*1.058) for i in [0, 55923, 61596, 67270, 72943, 78617, 84290, 89964, 95638, 101311, 106983, 112657, 118330, 124004, 129678, 135351, 141025, 146698, 152372, 158045, 163718, 169391, 175065, 180738, 186412, 192085, 197759, 203432, 209106, 214779, 220452, 226125, 231799, 237472, 243146,
                                    248819, 254493, 260166, 265840, 271513, 277187, 282859, 288533, 294206, 299880, 305553, 311227, 316901, 322574, 328248, 333921, 339593, 345267, 350941, 356614, 362288, 367961, 373635, 379308, 384982, 390655, 396329, 402001, 407675, 413348, 419022, 424695, 430369, 436042, 441716, 447389]]
    hit0 = 1
    风雷啸 = 1.7  # 风雷啸
    CD = 42
    是否有护石 = 1

    形态 = ['风雷啸', '普通']

    def 形态变更(self, 形态, char: Character):
        if 形态 == '' and len(self.形态) > 0:
            形态 = self.形态[0]
        if 形态 == "风雷啸":
            self.风雷啸 = 1.70
            if '奔雷螺旋击' in char.护石栏:
                # 护石会直接取代原本风雷啸的加成
                self.风雷啸 = 2.15
        if 形态 == '普通':
            self.风雷啸 = 1.00

    MP = [170, 1428]
    无色消耗 = 3

    def 装备护石(self):
        pass


class 技能20(主动技能):  # 月辉念气破
    名称 = '月辉念气破'
    所在等级 = 80
    等级上限 = 50
    学习间隔 = 2
    等级精通 = 40

    data0 = [int(i*1.051*1.056) for i in [0, 7404, 8154, 8906, 9657, 10409, 11160, 11910, 12662, 13413, 14165, 14915, 15666, 16418, 17169, 17921, 18671, 19422, 20174,
                                    20925, 21675, 22427, 23178, 23930, 24680, 25431, 26183, 26934, 27686, 28436, 29187, 29939, 30690, 31440, 32192, 32943, 33695, 34446, 35196, 35948, 36699]]
    hit0 = 10
    CD = 45
    是否有护石 = 1

    MP = [450, 1260]
    无色消耗 = 5

    def 装备护石(self):
        self.倍率 *= 1.3
        self.CDR *= 0.9


class 技能21(被动技能):  # 风雷啸
    名称 = '风雷啸'
    所在等级 = 75
    等级上限 = 50
    学习间隔 = 3
    是否主动 = 1
    等级精通 = 40
    关联技能 = ['所有']

    def 加成倍率(self, 武器类型):
        if self.等级 == 0:
            return 1.0
        else:
            return round(1.11 + 0.02 * self.等级, 5)


class 技能22(主动技能):  # 月华万象 二觉
    名称 = '月华万象'
    所在等级 = 85
    等级上限 = 50
    学习间隔 = 5
    等级精通 = 40

    data0 = [int(i*1.054*1.058) for i in [0, 5142, 6334, 7527, 8719, 9912, 11103, 12296, 13488, 14681, 15873, 17066, 18258, 19451, 20643, 21836, 23028, 24221, 25412, 26605, 27797, 28990, 30182, 31375,
                                    32567, 33760, 34952, 36145, 37336, 38529, 39721, 40914, 42106, 43299, 44491, 45684, 46876, 48069, 49261, 50454, 51645, 52838, 54030, 55223, 56415, 57608, 58800, 59993, 61185, 62378, 63570]]
    hit0 = 12
    data1 = [int(i*1.054*1.058) for i in [0, 107988, 133028, 158069, 183109, 208151, 233191, 258231, 283272, 308312, 333353, 358394, 383435, 408475, 433516, 458556, 483598, 508638, 533679, 558719, 583760, 608800, 633842, 658882, 683923,
                                    708963, 734005, 759045, 784085, 809126, 834166, 859207, 884248, 909289, 934329, 959370, 984410, 1009452, 1034492, 1059533, 1084573, 1109614, 1134654, 1159696, 1184736, 1209777, 1234817, 1259859, 1284899, 1309940, 1334980]]
    hit1 = 1
    CD = 180

    MP = [500, 4480]
    无色消耗 = 10


class 技能23(被动技能):  # 禅意·万象 三觉被动
    名称 = '禅意·万象'
    所在等级 = 95
    等级上限 = 40
    学习间隔 = 3
    等级精通 = 30
    关联技能 = ['所有']

    def 加成倍率(self, 武器类型):
        if self.等级 == 0:
            return 1.0
        else:
            return round(1.18 + 0.02 * self.等级, 5)


class 技能24(主动技能):  # 禅语·形灭
    名称 = '禅语·形灭'
    所在等级 = 95
    等级上限 = 50
    学习间隔 = 2
    等级精通 = 40

    data0 = [int(i*1.05*1.054) for i in [0, 4831, 5321, 5811, 6301, 6791, 7282, 7772, 8262, 8752, 9242, 9732, 10223, 10713, 11203, 11693, 12183, 12674, 13164, 13654, 14144, 14634, 15124, 15615, 16105,
                                   16594, 17084, 17574, 18064, 18554, 19045, 19535, 20025, 20515, 21005, 21496, 21986, 22476, 22966, 23456, 23946, 24437, 24927, 25417, 25907, 26397, 26887, 27378, 27868, 28358, 28848]]
    hit0 = 10
    data1 = [int(i*1.05*1.054) for i in [0, 48314, 53215, 58117, 63018, 67920, 72821, 77722, 82624, 87526, 92427, 97328, 102230, 107132, 112032, 116934, 121836, 126737, 131638, 136540, 141442, 146342, 151244, 156146, 161048,
                                   165948, 170850, 175752, 180654, 185554, 190456, 195358, 200259, 205160, 210062, 214963, 219865, 224766, 229668, 234569, 239471, 244372, 249273, 254175, 259077, 263978, 268879, 273781, 278683, 283583, 288485]]
    hit1 = 1
    风雷啸 = 1.7  # 风雷啸
    CD = 60.0

    MP = [773, 6000]
    无色消耗 = 7


class 技能25(主动技能):  # 禅念·归一 三觉
    名称 = '禅念·归一'
    所在等级 = 100
    等级上限 = 50
    学习间隔 = 5
    等级精通 = 40

    data0 = [int(i*1.05*1.055) for i in [0, 310639, 382672, 454704, 526736, 598768, 670800, 742833, 814866, 886898, 958931, 1030963, 1102995, 1175027, 1247059, 1319092, 1391125, 1463157, 1535190, 1607222, 1679254, 1751286, 1823318, 1895351, 1967383,
                                   2039416, 2111449, 2183481, 2255513, 2327545, 2399577, 2471610, 2543642, 2615675, 2687708, 2759740, 2831772, 2903804, 2975837, 3047869, 3119901, 3191933, 3263967, 3335999, 3408031, 3480063, 3552096, 3624128, 3696160, 3768192, 3840226]]
    hit0 = 1
    data1 = [int(i*1.05*1.055) for i in [0, 34515, 42518, 50522, 58525, 66529, 74532, 82536, 90541, 98543, 106548, 114551, 122555, 130558, 138562, 146566, 154569, 162573, 170576, 178580, 186583, 194587, 202591, 210594, 218598,
                                   226601, 234605, 242608, 250612, 258616, 266619, 274623, 282626, 290630, 298633, 306637, 314641, 322644, 330648, 338651, 346655, 354658, 362662, 370667, 378669, 386674, 394677, 402681, 410684, 418688, 426692]]
    hit1 = 6
    CD = 290.0

    MP = [4027, 8054]
    无色消耗 = 15


class classChange(Character):
    def __init__(self):
        self.实际名称 = 'nenmaster_male'
        self.名称 = '归元·气功师'
        self.角色 = '格斗家(男)'
        self.角色类型 = '输出'
        self.职业 = '气功师'
        # 用来筛CP武器的
        self.转职 = '气功师(男)'
        self.武器选项 = ['手套']
        self.输出类型选项 = ['魔法百分比']
        self.防具精通属性 = ['智力']
        self.类型 = '魔法百分比'
        self.武器类型 = '手套'
        self.防具类型 = '布甲'
        技能列表 = []
        技能序号 = {}
        i = 0
        while i >= 0:
            try:
                tem = eval('技能'+str(i)+'()')
                tem.基础等级计算()
                技能序号[tem.名称] = i
                技能列表.append(tem)
                i += 1
            except:
                i = -1
        self.技能栏 = 技能列表
        self.技能序号 = 技能序号
        self.buff = 1.43*1.21

        super().__init__()

    def 职业特殊计算(self):
        幻影碎爆 = self.get_skill_by_name('幻影碎爆')
        分身 = self.get_skill_by_name('分身')
        分身.基础个数 = 幻影碎爆.TP等级

        念气波 = self.get_skill_by_name('念气波')
        蓄念炮倍率 = self.get_skill_by_name('蓄念炮').加成倍率(self.武器类型)

        念气波.倍率 /= 蓄念炮倍率
        念气波.蓄念炮加成 = 蓄念炮倍率

        pass
